package com.titar.robot.utils;

import android.text.TextUtils;

public class TntUtil {
    //新的密码判断方式,长度是否为6到12
    public static boolean isNewLigalPsw(String psw) {
        //TODO:

        if (psw.length() >= 6 && psw.length() <= 12)
            return true;
        else return false;
        //return true;
    }

    public static  boolean isVerifyCode(String code){
        String num1 = "\\d{6}";// 6位纯数字验证码
        String num2 = "\\d{4}";//4位或6位纯数字验证码
        if (TextUtils.isEmpty(code))
            return false;
        return code.matches(num2) || code.matches(num1);
    }
}
